import java.util.Arrays;
import java.util.Scanner;

class Circle{
	private int radius;
	public Circle(int radius) {
		this.radius=radius;
	}
	public int getPerimeter(int radius) {
		double result=2*Math.PI*radius;
		return (int)result;
	}
	public int getArea(int radius) {
		double result=Math.PI*radius*radius;
		return (int)result;
	}
	public String toString() {
		return "Circle [radius=" + radius + "]";
	}
	
	
}
class Rectangle{
	private int width,length;
	public Rectangle(int width,int length) {
		this.width=width;
		this.length=length;
	}
	public int getPerimeter(int width,int length) {
		return (width+length)*2;
	}
	public int getArea(int width,int length) {
		return width*length;
	}
	public String toString() {
		return "Rectangle [width=" + width + ", length=" + length + "]";
	}
	
}
public class Main  {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner in=new Scanner(System.in 

);
		int result=0;
		int result1=0;
		Rectangle []rectangle=new Rectangle[2];
		Circle []circle=new Circle[2];
		for(int i=0;i<2;i++) {
			int a=in.nextInt();
			int b=in.nextInt();
			rectangle[i]=new Rectangle(a,b);
			result+=rectangle[i].getPerimeter(a,b);
			result1+=rectangle[i].getArea(a,b);
		}
		for(int j=0;j<2;j++) {
			int c=in.nextInt();
			circle[j]=new Circle(c);
			result+=circle[j].getPerimeter(c);
			result1+=circle[j].getArea(c);
		}
		System.out.println(result);
		System.out.println(result1);
		System.out.println(Arrays.deepToString(rectangle));
		System.out.println(Arrays.deepToString(circle));
		
	}
}